package com.spring.rpc.controller;

import com.spring.rpc.service.IHelloWord;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description
 * @Author cuiyaosheng
 * @Date 2018-03-23 10:33
 * @Modified by:
 **/
@RestController
public class HelloController {
    @Autowired
    IHelloWord helloWord;

    @GetMapping(path = {"/hello"})
    public String hello(String hello) throws RuntimeException{
        return helloWord.sayHello(hello);
    }
}
